
    <x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('Edit Blog') }}
        </h2>
    </x-slot>

    <div class="container mx-auto">
        <form action="{{ route('blogs.update', $blog) }}" method="POST">
            @method('PUT')
            @csrf
            <div class="mb-4">
                <label for="title" class="block text-gray-700 font-medium mb-2">Title</label>
                <input type="text" id="title" name="title" value="{{ $blog->title }}" class="border border-gray-400 p-2 w-full">
            </div>
            <div class="mb-4">
                <label for="body" class="block text-gray-700 font-medium mb-2">Body</label>
                <textarea name="body" id="body" class="border border-gray-400 p-2 w-full" rows="8">{{ $blog->body }}</textarea>
            </div>
            <div class="mb-4">
                <button type="submit" class="bg-blue-500 text-white py-2 px-4 rounded-full hover:bg-blue-600">Save</button>
                <a href="{{ route('blogs.index') }}" class="text-blue-500">Cancel</a>
            </div>
        </form>
    </div>
   </x-app-layout>





